home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_shs_vandal.cog < prev    next >
Text File  |  1999-11-15  |  1KB  |  70 lines

  1. # Jones 3D Cog Script
  2. #
  3. # shs_Window.cog "Scheiß das Fenster."     
  4. #  [JWC]
  5. #
  6. # (C) 1999 LucasArts Entertainment Co. All Rights Reserved
  7. # ========================================================================================
  8.  
  9. symbols
  10.     
  11.     message     startup
  12.     message     damaged
  13.     
  14.     material    brokenout
  15.     material    brokenin
  16.  
  17.     surface     insidewindow    mask=0x408        
  18.     surface        outsidewindow    mask=0x408    
  19.     
  20.     sound        shatter=shs_glassbreak.wav    local
  21.  
  22.     template    shards=iceshrapa        
  23.  
  24.     thing       player        local
  25.     thing        shardpos
  26.  
  27.     int            broken=0    local
  28.  
  29. end
  30.  
  31. # ========================================================================================
  32.  
  33. code
  34.  
  35. startup:
  36.     
  37.     player = GetLocalPlayerThing();
  38.     
  39.     return;
  40.     
  41. # ========================================================================================
  42.  
  43. damaged:
  44.         
  45.         if(broken == 0)
  46.         {
  47.             broken=1;
  48.             PlaySoundLocal(shatter, 1.0, 0, 0, 0);
  49.             
  50.             # Make stuff
  51.             CreateThing(shards, shardpos);
  52.             
  53.             # Swap Texture
  54.             SetSurfaceMat(insidewindow, brokenin);
  55.             SetSurfaceMat(outsidewindow,brokenout);
  56.             
  57.             # Make adjoin move
  58.             SetAdjoinFlags(insidewindow, 0x02);
  59.             SetAdjoinflags(outsidewindow, 0x02);
  60.  
  61.          }
  62.     return;
  63.  
  64. # ========================================================================================
  65.  
  66. end
  67.  
  68.  
  69.